/****************************************************
 * Description: ServiceImpl for 课程
 * Copyright:   Copyright (c) 2014
 * Company:     beiwaionline
 * @author      bfsu
 * @version     1.0
 * @see
	HISTORY
    *  2014-01-10 bfsu Create File
**************************************************/

package com.bfsuol.common.service.impl;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.bfsuol.common.dao.LoginDAO;
import com.bfsuol.common.service.LoginService;
import com.bfsuolframework.security.dao.BaseUserDAO;
import com.bfsuolframework.security.entity.BaseUser;
import com.bfsuolframework.core.service.ServiceSupport;


@Service
public class LoginServiceImpl extends ServiceSupport<BaseUser> implements LoginService {

    @Autowired
    private LoginDAO loginDAO;
    @Autowired
    private BaseUserDAO baseUserDAO;
    
    @Override
    public LoginDAO getDao() {
        return loginDAO;
    }

	public BaseUser getBaseUserByLogin(String loginName,String password){
    	return loginDAO.getBaseUserByLogin(loginName, password);
    }
/*
 * (non-Javadoc)
 * @see com.bfsuol.lms2014.common.service.LoginService#getBaseUserByEmail(java.lang.String, java.lang.String)
 */
	public BaseUser getBaseUserByEmail(String loginName, String email) {
		return loginDAO.getBaseUserByEmail(loginName,email);
	}

}